home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic 5 Developer's Kit / vb5 dev kit.iso / dev / regdll / readme.tx_ / readme.tx
Encoding:
Text File  |  1996-02-11  |  9.8 KB  |  187 lines

  1. The Galaxy Software Registration DB OLE Server DLL allows the developer to
  2. access the registration database using the standard object syntax that all
  3. Visual Basic programmers have become accustomed to.  This OLE DLL was
  4. created with Microsoft Visual Basic 4.0 Professional Edition and has been
  5. tested under Microsoft Windows 95.  It should also function under Microsoft
  6. Windows NT 3.51 although this capability has not been tested.
  7.     
  8.     Note:   To see a listing of the required parameters for each method and
  9.             property please refer to the Object Browser on the View menu in
  10.             the Visual Basic IDE interface.
  11.  
  12. ===========================================================================
  13. Installation:
  14.  
  15. To install this product on your computer all you need to do is run the
  16. setup program.
  17.     1)  In Windows 95 click on the start menu and select run.
  18.     2)  Type X:\Setup.exe or click Browse and find setup.exe.
  19.     3)  Click on the OK button.
  20.     
  21. To uninstall this product
  22.     1)  In Windows 95 click on the start menu and select Settings.
  23.     2)  Select the Control Panel option.
  24.     3)  In control panel double click on Add/Remove Programs.
  25.     4)  Select GalaxySoft Registration DB OLE Server and click remove.
  26.     
  27. ===========================================================================
  28. The Registration DB OLE DLL contains the following objects:
  29.  
  30.     Object      Description
  31.     ------      -----------------------------------------------------------
  32.     RegStr      Allows access to string values.
  33.     RegInt      Allows access to integer values.
  34.     RegLng      Allows access to long integer values.
  35.     RegSgl      Allows access to floating point single values.
  36.     RegDbl      Allows access to floating point double values.
  37.  
  38. ===========================================================================
  39. Each of the above objects contain the following methods:
  40.  
  41.     Method              Description
  42.     -----------------   ---------------------------------------------------
  43.     obj.Register        Register the object to the specified HKey, section,
  44.                         and key.  Also allows you to specify a default
  45.                         value.
  46.     obj.RemoveKey       Deletes the registered key from the registration
  47.                         database.  Generates run-time error if the key does
  48.                         not exist.
  49.     obj.RemoveSection   Deletes the registered section and all associated
  50.                         keys from the registration database.  Generates a
  51.                         run-time error if the section does not exist.
  52.  
  53. ===========================================================================
  54. Each of the above objects contain the following properties:
  55.  
  56.     Property      Description
  57.     -----------   ---------------------------------------------------------
  58.     obj.HKey      Returns the HKey that was set in the Register method. The
  59.                   return data type is long.  Valid HKey's are HKEY_USERS,
  60.                   HKEY_CURRENT_USER, HKEY_CLASSES_ROOT, HKEY_LOCAL_MACHINE.
  61.                   (read-only)
  62.     obj.Section   Returns the section that was set in the Register method.
  63.                   The return data type is string.  (read-only)
  64.     obj.Key       Returns the key that was set in the Register method.
  65.                   The return data type is string.  (read-only)
  66.     obj.Default   Returns the default value that was set in the Register
  67.                   method.  The return data type is determined by the object
  68.                   type.  Ex: RegDbl returns double, RegStr returns string.
  69.                   (read-only)
  70.     obj.Value     Sets or returns the value for the HKey, section, and key
  71.                   set in the Register method.  The data type is determined
  72.                   by the object type.  Ex: RegInt is integer, RegLng is
  73.                   long.  This property will return the default value if the
  74.                   specified HKey, section, or key cannot be found.
  75.     obj.Version   Returns the version number of the object.  The return
  76.                   data type is string.  (read-only)
  77.  
  78. ===========================================================================
  79. The INI File OLE Server DLL traps and throws the follwing error conditions:
  80.  
  81.     Constant                        Value       Description
  82.     ----------------------------    -----       ---------------------------    
  83.     gknRSErrInvalidSection          1001        This error occurs if an
  84.                                                 empty string is provided
  85.                                                 for the section in the
  86.                                                 Register method.
  87.     gknRSErrInvalidKey              1002        This error occurs if an
  88.                                                 empty string is provided
  89.                                                 for the key in the Register
  90.                                                 method.
  91.     gknRSErrRegBaseNotRegistered    1003        This error occurs if any of
  92.                                                 the properties except for
  93.                                                 Version are accessed before
  94.                                                 the Register method is
  95.                                                 invoked.
  96.     gknRSErrInvalidHKey             1004        This error occurs if an
  97.                                                 HKey other than HKEY_USERS,
  98.                                                 HKEY_CURRENT_USER,
  99.                                                 HKEY_CLASSES_ROOT, or
  100.                                                 HKEY_LOCAL_MACHINE is
  101.                                                 specified.
  102.     gknRSErrRemoveKey               1005        This error occurs if the
  103.                                                 specified key does not
  104.                                                 exist.
  105.     gknRSErrRemoveSection           1006        This error occurs if the
  106.                                                 specified section does not
  107.                                                 exist.
  108.     gknRSErrSetValue                1007        This error occurs if the
  109.                                                 specified key cannot be set
  110.                                                 
  111. Per Microsoft recomendations the returned error values will be the value
  112. shown in the table above plus the vbObjectError constant from Visual Basic.
  113.  
  114. These constants are defined in the RegConst.bas file.
  115.  
  116. ===========================================================================
  117. Examples:
  118.  
  119.     Before using a registration DB object you must first create the object.
  120.     An example is shown below.
  121.         
  122.         Private moRegStr As New RegDBServer.RegStr
  123.  
  124.     Now that you have an object variable defined you must use the Register
  125.     method to initialize it to a specific HKey, section and key.
  126.     
  127.         moRegStr.Register sSection, sKey, lHKey, sDefault
  128.  
  129.         Note:  The Register method also has a 5th parameter of type boolean.
  130.                If TRUE this parameter forces the value to be obtained from
  131.                the registration DB each time the Value property is read.  If
  132.                FALSE the value is read from the registration DB only the
  133.                first time the Value property is read.  The default for this
  134.                parameter is FALSE.
  135.         Note:  The Register method can be called multiple times on the same
  136.                object.  This procedure just reinitializes the existing Reg
  137.                DB object and does not create a new object.
  138.                
  139.     Now you can access the other methods and properties as required.
  140.     
  141.         sValue = moRegStr.Value     'Get the value of the specified key.
  142.         moRegStr.Value = sValue     'Set the value of the specified key.
  143.         
  144.         lHKey = moRegStr.HKey       'Get the registered HKey.
  145.         sSection = moRegStr.Section 'Get the registered section name.
  146.         sKey = moRegStr.Key         'Get the registered key name.
  147.         sDefault = moRegStr.Default 'Get the registered default value.
  148.         sVersion = moRegStr.Version 'Get the version number of the object.
  149.         
  150.         moRegStr.RemoveSection      'Deletes the registered section and all
  151.                                     'associated sub-sections and keys from
  152.                                     'the registration database.
  153.         moRegStr.RemoveKey          'Deletes the registered key from the
  154.                                     'registration database.
  155.  
  156. ===========================================================================
  157. Technical Support:
  158.  
  159. You can contact Galaxy Software for technical support, questions or comment
  160. by any of the following methods:
  161.  
  162.     Snail Mail:         Galaxy Software
  163.                         7044 St. Joe Road
  164.                         Fort Wayne, IN  46835
  165.                     
  166.     E-Mail:
  167.         Internet:       galaxysoft@msn.com
  168.         AOL:            GalaxySoft
  169.         MSN:            GalaxySoft
  170.         Compuserve:     102167,2656
  171.         
  172.     World Wide Web:     http://users.aol.com/galaxysoft/
  173.     
  174. ===========================================================================
  175. Legal stuff:
  176.  
  177. The Galaxy Software Registration DB OLE Server DLL is copyrighted SHAREWARE
  178. This is not freeware and cannot be redistributed as a component of your
  179. projects until you have registered the product.  You are free to evaluate
  180. this product for 30 days after which if you intend to continue using it you
  181. will be required to register.  You are free to distribute this product to
  182. other developers for eavaluation purposes only and only if the entire
  183. package is intact as when it was recieved by you.  Please refer to
  184. register.txt for information on registering this product.
  185.  
  186. Copyright ⌐ 1996 - Galaxy Software
  187.